package easy;

public class q191 {

    public static void main(String[] args) {
        System.out.println(4&3);
        int n = 0000000000000000000001111;
        System.out.println(Integer.toBinaryString(585));
        System.out.println(hammingWeight(n));
    }

    public static int hammingWeight(int n) {
        System.out.println(n);
        int ret = 0;
        while (n != 0) {
            n = n & (n-1);
            ret++;
        }
        return ret;
    }

}
